<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<%@ page import="blog1.articleDAO" %>
<%@ page import="blog1.article" %>  
<%@ page import= "java.util.ArrayList" %> 
<%@ page import="java.util.Date"%>
<%@ page import="java.text.SimpleDateFormat"%>

<!-- 博文存放的页面 -->

<html>
<head>
<title>博文</title>
<meta charset="utf-8">
<meta name="renderer" content="webkit|ie-comp|ie-stand">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
<meta http-equiv="Cache-Control" content="no-siteapp" />
<LINK rel="Bookmark" href="favicon.ico" >
<LINK rel="Shortcut Icon" href="favicon.ico" />
<!--[if lt IE 9]>
<script type="text/javascript" src="/staticRes/js/html5shiv.js"></script>
<script type="text/javascript" src="/staticRes/js/respond.min.js"></script>
<![endif]-->
<link rel="stylesheet" type="text/css" href="plugin/h-ui/css/H-ui.min.css" />
<link rel="stylesheet" type="text/css" href="plugin/Hui-iconfont/1.0.8/iconfont.min.css" />
<link rel="stylesheet" type="text/css" href="css/common.css" />
<link rel="stylesheet" type="text/css" href="plugin/pifu/pifu.css" />
<!--[if lt IE 9]>
<link href="/staticRes/lib/h-ui/css/H-ui.ie.css" rel="stylesheet" type="text/css" />
<![endif]-->
<script type="application/x-javascript"> addEventListener("load", function() { setTimeout(hideURLbar, 0); }, false); function hideURLbar(){ window.scrollTo(0,1); } function showSide(){$('.navbar-nav').toggle();}</script>
</head>
<body>
<header class="navbar-wrapper">
    <div class="navbar navbar-fixed-top">
        <div class="container cl">
            <a class="navbar-logo hidden-xs" href="index.jsp">
                <img class="logo" src="img/one.png" alt="我的博客" />
            </a>
            <a aria-hidden="false" class="nav-toggle Hui-iconfont visible-xs" href="javascript:void(0);" onclick="showSide();">&#xe667;</a>
            <nav class="nav navbar-nav nav-collapse w_menu" role="navigation">
                <ul class="cl">
					<li class="active"> <a href="index.jsp" data-hover="首页">首页</a> </li>
                    <li> <a href="about.jsp" data-hover="关于博主">关于博主</a> </li>
                    <li> <a href="write.jsp" data-hover="撰写博文">撰写博文</a> </li>
                    <li><a href="article.jsp" data-hover="博文一览">博文一览</a></li>
                    <li> <a href="board.jsp" data-hover="留言板">留言板</a> </li>
                </ul>
                
            </nav>
        </div>
    </div>
</header>

<!--导航条-->
<nav class="breadcrumb">
    <div class="container">
        <i class="Hui-iconfont">&#xe67f;</i><a href="index.jsp" class="c-primary">首页</a>
        <span class="c-gray en">&gt;</span> <a href="#" class="c-primary">博文一览</a>
    </div>
</nav>

<section class="container">
  <!--left-->
  <div class="col-sm-9 col-md-9 mt-20">
  	
  		
  	<!--article list-->
			<ul class="index_arc">
				<%
					articleDAO articledao=new articleDAO(); 
					ArrayList <article> list= articledao.getAllarticle(); 
					if(list!=null && list.size()>0)
					{
						for(int i=list.size()-1;i>=0;i--)
						{ 
							article artic=list.get(i);
			                String outline=artic.getArticleName();
			                String passage=artic.getArticleContent();
			                String passageGood=Integer.toString(artic.getArticleGood());
			                String passageDate=artic.getArticleDate();
			                String passageTime=artic.getArticleTime();
                %>
				<li class="index_arc_item">
	            <a href="/article/4" class="pic">
	                <img class="lazyload" data-original="temp/art.jpg" alt="centos 6.5 nginx安装及配置" >
	            </a>
                <h4 class="title"><a href="article_detail.jsp?outline=<%=outline%>&passage=<%=passage%>&passageGood=<%=passageGood %>&date=<%=passageDate%>&time=<%=passageTime %>"><%=outline %></a></h4>
	        <div class="date_hits">
	            <span>连理</span>
	            <span><%=passageDate %>&nbsp&nbsp&nbsp<%=passageTime %></span>
	            <span>
	                <a href="/article?t=1">程序人生</a>
	            </span>
	            <p class="hits"><i class="Hui-iconfont" title="点击量"></i> <%=passageGood %>° </p>
	            <p class="commonts"><i class="Hui-iconfont" title="评论"></i> <span class="cy_cmt_count">0</span></p>
	        </div>
	        <div class="desc"><%=passage %></div>
	    </li>
	    <%  
					} 
				}
	    %>
	    			</ul>
  		<div class="text-c mb-20" id="moreBlog">
            <a class="btn  radius btn-block " href="javascript:;" onclick="moreBlog('${blogType.id}','${tag.name}');">点击加载更多</a>
            <a class="btn  radius btn-block hidden" href="javascript:;">加载中……</a>
        </div>		
  </div>
  
  

  
</section>
<footer class="footer mt-20">
    <div class="container-fluid" id="foot">
        <p>大连梦创信息<br>
            大连理工大学暑期研修小组
        </p>
    </div>
</footer>
<script type="text/javascript" src="plugin/jquery/1.9.1/jquery.min.js"></script>
<script type="text/javascript" src="plugin/layer/3.0/layer.js"></script>
<script type="text/javascript" src="plugin/h-ui/js/H-ui.min.js"></script>
<!-- <script type="text/javascript" src="plugin/pifu/pifu.js"></script> -->
<script type="text/javascript" src="js/common.js"></script>
<script> $(function(){ $(window).on("scroll",backToTopFun); backToTopFun(); }); </script>
<script>
$(function(){
//标签
	$(".tags a").each(function(){
		var x = 9;
		var y = 0;
		var rand = parseInt(Math.random() * (x - y + 1) + y);
		$(this).addClass("tags"+rand)
	});
	
	$("img.lazyload").lazyload({failurelimit : 3});
});

</script> 
</body>
</html>